<?php
use Phalcon\Cli\Task;
class OtherTask extends Task
{
    /**
     * 10分钟未支付取消
     */
    public function selfOrderNoPayAction(){
        $BShopOrderDb = new \Common\Models\BShopOrder();
        $get_list = $BShopOrderDb->nopay();
        foreach($get_list as $key=>$value){
            //$this->dbMaster->begin();
            $value->status = -1;
            $datatime = date('Y-m-d H:i:s');
            $value->tips .="|10分钟没有付款自动取消{$datatime}";
            $value->save();
        }
        var_dump("一共".count($get_list->toarray()).'条数据');

    }
}
